﻿#include <iostream>
#include <stack>
using namespace std;
int main()
{
	stack<int> st;
	// 先讲1~10进栈
	for (int i = 1; i <= 10; i++)
	{
		st.push(i);
	}
	while (st.size()) // !st.empty()
	{
		cout << st.top() << endl;
		st.pop();
	}
	return 0;
}
//#define _CRT_SECURE_NO_WARNINGS 1
//#include<iostream>
//using namespace std;
//const int N = 1e5 + 10;
////创建栈
//int stk[N], n;
////进栈-本质就是顺序表⾥⾯的尾插
//void push(int x)
//{
//	stk[++n] = x;
//}
////出栈-顺序表的尾删操作
//void pop()
//{
//	n--;
//}
////查询栈顶元素
//int top()
//{
//	return stk[n];
//}
////判断是否为空
//bool empty()
//{
//	return n == 0;
//}
////查询有效元素的个数
//int size()
//{
//	return n;
//}
//int main()
//{
//	for (int i = 1; i <= 10; i++)
//	{
//		push(i);
//	}
//	// 当栈不为空的时候
//	while (!empty())//while(size())
//	{
//		cout << top() << endl;
//		pop();
//	}
//	return 0;
//}
////#define _CRT_SECURE_NO_WARNINGS 1
////#include<iostream>
////using namespace std;
////const int N = 110;
////int ne[N];
////int n,m;
////int main()
////{
////	cin >> n >> m;
////	for (int i = 1; i <= n; i++)
////	{
////		ne[i] = i+1;
////	}
////
////	ne[n] = 1;
////
////	int t = n;
////	for (int i = 1; i <= n; i++)
////	{
////		for (int j = 1; j < m; j++)
////		{
////			t = ne[t];
////		}
////		cout << ne[t] << " ";
////		ne[t] = ne[ne[t]];
////	}
////	return 0;
////}
////const int N = 1e5+10;
////int h,ne[N],pre[N];
////int st[N];//st[i]表示x这个元素是否已经被删除
////int n, m;
////int main()
////{
////	cin >> n;
////	pre[1] = h;
////	ne[h] = 1;
////
////	for (int i = 2; i <= n; i++)
////	{
////		int k, p; cin >> k >> p;
////		if (p == 0)
////		{
////			ne[i] = k;
////			pre[i] = pre[k];
////			ne[pre[k]] = i;
////			pre[k] = i;
////		}
////		else
////		{
////			pre[i] = k;
////			ne[i] = ne[k];
////			pre[ne[k]] = i;
////			ne[k] = i;
////		}
////	}
////	cin >> m;
////	while (m--)
////	{
////		int x; cin >> x;
////		if (st[x] == true)continue;
////
////		ne[pre[x]] = ne[x];
////		pre[ne[x]] = pre[x];
////		st[x] = true;
////	}
////	for (int i = ne[h]; i; i = ne[i])
////	{
////		cout << i << " ";
////	}
////	return 0;
////}
////int main()
////{
////	int q;
////	cin >> q;
////
////	id++;
////	ne[id] = 1;
////	mp[1] = id;
////	while (q--)
////	{
////		int op, x, y;
////		cin >> op >> x;
////		int p = mp[x];
////		if (op == 1)
////		{
////			cin >> y;
////			id++;
////			e[id] = y;
////			ne[id] = ne[p];
////			ne[p] = id;
////
////			mp[y] = id;
////		}
////		else if (op == 2)
////		{
////			cout << e[ne[p]] << endl;
////		}
////		else
////		{
////			ne[p] = ne[ne[p]];
////
////		}
////	}
////	return 0;
////}